package com.example.demo1.service.Impl;

import com.example.demo1.mapper.OrderMapper;
import com.example.demo1.model.Order;
import com.example.demo1.service.OrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class OrderServiceImpl implements OrderService {
    @Autowired
    OrderMapper orderMapper;
    @Override
    public List<Order> getOrderList() {
        return orderMapper.getOrderList();
    }

    @Override
    public List<Order> getOrders(int orderId) {
        return orderMapper.getOrders(orderId);
    }

    @Override
    public int deleteOrder(int orderId) {
        return orderMapper.deleteOrder(orderId);
    }

    @Override
    public int updateFlightId(int flightId, int orderId) {
        return orderMapper.updateFlightId(flightId, orderId);
    }
}
